package acwing.模拟;

import java.util.Scanner;

/**
 * 成绩统计
 *
 * @author yang
 * @date 2021/12/16
 */
public class 成绩统计 {
    static int N = 10010;
    static int[] arr = new int[N];
    static int n;

    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        n = sc.nextInt();
        int x = 0; // 及格
        int y = 0; // 优秀
        for (int i = 0; i < n; i++) {
            arr[i] = sc.nextInt();
        }
        for (int i = 0; i < n; i++) {
            if (arr[i] >= 60) x++;
            if (arr[i] >= 85) y++;
        }

        System.out.println(Math.round(x * 100.0 / n) + "%");
        System.out.println(Math.round(y * 100.0 / n) + "%");
    }
}
